package com.ldj.base;

import org.hibernate.Session;
import org.hibernate.SessionFactory;

/**
 * All rights Reserved, Designed By 翼虎能源
 * Copyright:    Copyright(C) 2015-2015
 * Company       北京翼虎能源科技有限公司
 *
 * @author 吕东杰
 * @version 1.0
 * @date 2016/5/26 15:54
 * @Description Demo
 */
public abstract class AbstractHibernateDaoSupport {
    public AbstractHibernateDaoSupport() {
    }

    protected abstract SessionFactory getSessionFactory();

    protected Session getSession() {
        return this.getSessionFactory().getCurrentSession();
    }
}

